<?php
namespace app\index\model;
use Think\Model;
/**
 * 基础model
 */
class index extends \think\Model{
   //增加数据
       public function addData($data){
        $id=$this->add($data);
        return $id;
    }
   //修改数据
    public function editData($map,$data){
        $result=$this->where($map)->save($data);
        return $result;
    }
   //删除数据
    public function deleteData($map){
        $result=$this->where($map)->delete();
        return $result;
    }
}